import request from '@/utils/request'

// 新增员工
export const addEmployeeService = (employeeAddDTO) => {
  return request.post('/admin/employee/add', employeeAddDTO)
}

// 员工分页查询
export const employeePageQueryService = (employeePageQueryDTO) => {
  return request.get('/admin/employee/page', { params: employeePageQueryDTO })
}

// 根据员工id查询员工信息
export const getEmployeeByIdService = (id) => {
  return request.get(`/admin/employee/${id}`)
}

// 修改员工信息
export const updateEmployeeService = (employeeUpdateDTO) => {
  return request.put('/admin/employee', employeeUpdateDTO)
}

// 删除员工
export const deleteEmployeeService = (id) => {
  return request.delete(`/admin/employee/${id}`)
}
